<?php

/**
 * Description of Root.php.
 *
 * @package fruits
 * @author zhenhao<hit_zhenhao@163.com>
 */
namespace Real\App;

use Silex\Application;
use Symfony\Component\HttpFoundation\Request;

class Root extends Base
{
    public function index(Request $req, Application $app)
    {
        return 'Hello world';
    }

    public function hello(Request $req, Application $app)
    {
        $name = $req->get('name');
        return $this->render('hello/index.html', [
            'name' => $name
        ]);
    }
}